<template>
  <div class="main">
    <n-result status="404" title="资源不存在" description="生活总归带点荒谬" size="huge">
      <template #footer>
        <n-button @click="toHomePage" type="primary">返回首页</n-button>
        <n-button @click="toBack">原路返回</n-button>
      </template>
    </n-result>
  </div>
</template>

<script>
export default {
  name: "NotFound",
  methods: {
    toHomePage() {
      this.$router.push({path: '/'})
    },
    toBack() {
      this.$router.back();
    }
  }
}
</script>

<style scoped>
.main {
  height: 90vh;
  display: flex;
  align-items: center;
  justify-content: center;
}

.n-button {
  margin: 0 1rem
}
</style>
